package com.cms.sys.controller;

import com.cms.utils.AjaxResult;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HomeController {

    @GetMapping("/unauthorized")
    public AjaxResult unauthorizedRole(){
        System.out.println("------没有权限-------");
        return AjaxResult.error("没有权限");
    }

    @GetMapping("/unauthorizedLogin")
    public AjaxResult login() {
        return AjaxResult.error("请先去登录");
    }

}
